#images of java8
FROM centos:7
MAINTAINER ray<youcamhhhh@qq.com>

#拷贝后自动解压，如果不需要解压，可以使用COPY
ADD jdk-8u202-linux-x64.tar.gz /usr/local/java

# docker build 运行
RUN \
  yum update -y && \
  yum -y install epel-release && \
  yum install --assumeyes python3-pip && pip3 install --upgrade pip && \
  yum clean all && \
  pip3 install supervisor && \
## 在容器中创建/usr/local/java/jdk1.8.0_291与/usr/local/java/jdk的软连接
  ln -s /usr/local/java/jdk1.8.0_202 /usr/local/java/jdk

## 配置jdk环境
ENV JAVA_HOME=/usr/local/java/jdk \
JRE_HOME=/usr/local/java/jdk/jre \
CLASSPATH=.:/usr/local/java/jdk/lib:/usr/local/java/jdk/jre/lib \
PATH=/usr/local/java/jdk/bin:$PATH



ADD container-files /

# docker run 运行
CMD ["sh","/config/bootstrap.sh"]
